package ocean.chinacraft.common.config;

import net.minecraftforge.common.ForgeConfigSpec;

/**
 * 配置文件
 *
 * @author zhang
 * @since 2021/11/21
 */
public class ApplicationConfig {

    public static final ForgeConfigSpec.Builder BUILDER = new ForgeConfigSpec.Builder();

    public static final ForgeConfigSpec SPEC;

    /**
     * 需要多少饱食度才能使用影身功能
     */
    public static final ForgeConfigSpec.ConfigValue<Integer> NEED_FOOD;

    /**
     * 是否启用无限耐久
     */
    public static final ForgeConfigSpec.BooleanValue ENABLE_INFINITE_DURABILITY;

    /**
     * 如果主动攻击怪物，就算穿戴夜行衣也会被发现
     */
    public static final ForgeConfigSpec.ConfigValue<Boolean> NIGHT_ARMOR_SWITCH;


    static {
        BUILDER.push("Config for ChinaCraft Mod !");

        NEED_FOOD = BUILDER.comment("需要多少饱食度才能使用影身功能").define("NEED_FOOD", 14);
        ENABLE_INFINITE_DURABILITY = BUILDER
                .comment("是否提供无线耐久")
                .define("ENABLE_INFINITE_DURABILITY", false);

        NIGHT_ARMOR_SWITCH = BUILDER.comment("如果主动攻击怪物，就算穿戴夜行衣也会被发现").define("AI_LOCK", true);
        SPEC = BUILDER.build();
    }
}